import {request} from './request';

export const TYPE_TASK_CTL = 'task_ctl';
export const TYPE_STATUS_CTL = 'status_ctl';

export const fetchActions = (type, state, page, rows) => request({
    url: '/api/token/sc-action/_by-type',
    method: 'get',
    params: {
        type: type,
        page: page,
        rows: rows,
        state: state,
    }
});

export const createTaskAction = params => request({
    url: '/api/token/sc-action/_order-task',
    method: 'put',
    data: params,
});